<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>Kinetis Bootloader: Memory Interface</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="nxp_logo_small.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Kinetis Bootloader
   &#160;<span id="projectnumber">2.0.0</span>
   </div>
   <div id="projectbrief">Common bootloader for Kinetis devices</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Introduction</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li class="current"><a href="modules.html"><span>Modules</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__memif.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#enum-members">Enumerations</a> &#124;
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a>  </div>
  <div class="headertitle">
<div class="title">Memory Interface</div>  </div>
</div><!--header-->
<div class="contents">

<p>Abstract memory interface.  
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:structmemory__interface__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#structmemory__interface__t">memory_interface_t</a></td></tr>
<tr class="memdesc:structmemory__interface__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to memory operations.  <a href="group__memif.html#structmemory__interface__t">More...</a><br /></td></tr>
<tr class="separator:structmemory__interface__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:structmemory__region__interface__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a></td></tr>
<tr class="memdesc:structmemory__region__interface__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to memory operations for one region of memory.  <a href="group__memif.html#structmemory__region__interface__t">More...</a><br /></td></tr>
<tr class="separator:structmemory__region__interface__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:structmemory__map__entry__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#structmemory__map__entry__t">memory_map_entry_t</a></td></tr>
<tr class="memdesc:structmemory__map__entry__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">Structure of a memory map entry.  <a href="group__memif.html#structmemory__map__entry__t">More...</a><br /></td></tr>
<tr class="separator:structmemory__map__entry__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga51efad3b9aee5bd111a096728594b84a"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga51efad3b9aee5bd111a096728594b84a"></a>enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga51efad3b9aee5bd111a096728594b84a">_memory_interface_status</a> { <br />
&#160;&#160;<b>kStatusMemoryRangeInvalid</b> = MAKE_STATUS(kStatusGroup_MemoryInterface, 0), 
<br />
&#160;&#160;<b>kStatusMemoryReadFailed</b> = MAKE_STATUS(kStatusGroup_MemoryInterface, 1), 
<br />
&#160;&#160;<b>kStatusMemoryWriteFailed</b> = MAKE_STATUS(kStatusGroup_MemoryInterface, 2), 
<br />
&#160;&#160;<b>kStatusMemoryCumulativeWrite</b> = MAKE_STATUS(kStatusGroup_MemoryInterface, 3), 
<br />
&#160;&#160;<b>kStatusMemoryAppOverlapWithExecuteOnlyRegion</b> = MAKE_STATUS(kStatusGroup_MemoryInterface, 4)
<br />
 }<tr class="memdesc:ga51efad3b9aee5bd111a096728594b84a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory interface status codes. <br /></td></tr>
</td></tr>
<tr class="separator:ga51efad3b9aee5bd111a096728594b84a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaac34dfe6c6b73b43a4656c9dce041034"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom">{ <br />
&#160;&#160;<a class="el" href="group__memif.html#ggaac34dfe6c6b73b43a4656c9dce041034af06df00d223a4972f78ba2ed3282296c">kMemoryNotExecutable</a> = false, 
<br />
&#160;&#160;<a class="el" href="group__memif.html#ggaac34dfe6c6b73b43a4656c9dce041034acf4fb7fb9c61d4222ec903de4e194f1a">kMemoryIsExecutable</a> = true
<br />
 }</td></tr>
<tr class="separator:gaac34dfe6c6b73b43a4656c9dce041034"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gada22a2d32e1fc49d3a94d7d78cc0eae1"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gada22a2d32e1fc49d3a94d7d78cc0eae1">_memorymap_constants</a> { <br />
&#160;&#160;<b>kIndexFlashArray</b> = 0, 
<br />
&#160;&#160;<b>kIndexSRAM</b> = 1, 
<br />
&#160;&#160;<b>kIndexDTCM</b> = 2, 
<br />
&#160;&#160;<b>kIndexOCRAM</b> = 3, 
<br />
&#160;&#160;<b>kIndexQspiMemory</b> = 2, 
<br />
&#160;&#160;<b>kIndexQspiAliasArea</b> = 3, 
<br />
&#160;&#160;<a class="el" href="group__memif.html#ggada22a2d32e1fc49d3a94d7d78cc0eae1ae84ce932957cf2c1b62a763221d4ce2e">kSRAMSeparatrix</a> = (uint32_t)0x20000000
<br />
 }<tr class="memdesc:gada22a2d32e1fc49d3a94d7d78cc0eae1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory Map index constants.  <a href="group__memif.html#gada22a2d32e1fc49d3a94d7d78cc0eae1">More...</a><br /></td></tr>
</td></tr>
<tr class="separator:gada22a2d32e1fc49d3a94d7d78cc0eae1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6265b0d880b733e90deb99d99c7868de"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga6265b0d880b733e90deb99d99c7868de"></a>enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga6265b0d880b733e90deb99d99c7868de">flash_erase_all_option_t</a> { <br />
&#160;&#160;<b>kFlashEraseAllOption_Blocks</b> = 0, 
<br />
&#160;&#160;<b>kFlashEraseAllOption_ExecuteOnlySegments</b> = 1
<br />
 }<tr class="memdesc:ga6265b0d880b733e90deb99d99c7868de"><td class="mdescLeft">&#160;</td><td class="mdescRight">flash memory erase all options. <br /></td></tr>
</td></tr>
<tr class="separator:ga6265b0d880b733e90deb99d99c7868de"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gae959d45f5dadfeab2eb21bea2aa6691b"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gae959d45f5dadfeab2eb21bea2aa6691b"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gae959d45f5dadfeab2eb21bea2aa6691b">host_flash_erase_all</a> (void)</td></tr>
<tr class="memdesc:gae959d45f5dadfeab2eb21bea2aa6691b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all flash. <br /></td></tr>
<tr class="separator:gae959d45f5dadfeab2eb21bea2aa6691b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga4acc9107c77aca1f22aee34dcd1eb002"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga4acc9107c77aca1f22aee34dcd1eb002"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga4acc9107c77aca1f22aee34dcd1eb002">host_flash_erase_all_unsecure</a> (void)</td></tr>
<tr class="memdesc:ga4acc9107c77aca1f22aee34dcd1eb002"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all flash (unsecure). <br /></td></tr>
<tr class="separator:ga4acc9107c77aca1f22aee34dcd1eb002"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga212f4fe7a9764d6004412d4bc4ee1e62"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga212f4fe7a9764d6004412d4bc4ee1e62"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga212f4fe7a9764d6004412d4bc4ee1e62">host_flash_erase_region</a> (uint32_t address, uint32_t count)</td></tr>
<tr class="memdesc:ga212f4fe7a9764d6004412d4bc4ee1e62"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase a region of flash. <br /></td></tr>
<tr class="separator:ga212f4fe7a9764d6004412d4bc4ee1e62"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
Variables</h2></td></tr>
<tr class="memitem:ga0cc5deda096db2c6f7022ae58c8e594f"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga0cc5deda096db2c6f7022ae58c8e594f"></a>
<a class="el" href="group__memif.html#structmemory__map__entry__t">memory_map_entry_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga0cc5deda096db2c6f7022ae58c8e594f">g_memoryMap</a> []</td></tr>
<tr class="memdesc:ga0cc5deda096db2c6f7022ae58c8e594f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory map for the system. <br /></td></tr>
<tr class="separator:ga0cc5deda096db2c6f7022ae58c8e594f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0d5cfabb2d96ea6e9945886d87ad4734"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga0d5cfabb2d96ea6e9945886d87ad4734"></a>
static const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga0d5cfabb2d96ea6e9945886d87ad4734">s_flushMemoryInterface</a> = NULL</td></tr>
<tr class="memdesc:ga0d5cfabb2d96ea6e9945886d87ad4734"><td class="mdescLeft">&#160;</td><td class="mdescRight">This variable is used to do flush operation, it is bind to write operation. <br /></td></tr>
<tr class="separator:ga0d5cfabb2d96ea6e9945886d87ad4734"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa7d0fb25995fae36c7bfd95619857a84"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__interface__t">memory_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gaa7d0fb25995fae36c7bfd95619857a84">g_memoryInterface</a></td></tr>
<tr class="memdesc:gaa7d0fb25995fae36c7bfd95619857a84"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to generic memory operations.  <a href="#gaa7d0fb25995fae36c7bfd95619857a84">More...</a><br /></td></tr>
<tr class="separator:gaa7d0fb25995fae36c7bfd95619857a84"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Memory interfaces</h2></td></tr>
<tr class="memitem:gaa7d0fb25995fae36c7bfd95619857a84"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__interface__t">memory_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gaa7d0fb25995fae36c7bfd95619857a84">g_memoryInterface</a></td></tr>
<tr class="memdesc:gaa7d0fb25995fae36c7bfd95619857a84"><td class="mdescLeft">&#160;</td><td class="mdescRight">Abstract memory interface.  <a href="#gaa7d0fb25995fae36c7bfd95619857a84">More...</a><br /></td></tr>
<tr class="separator:gaa7d0fb25995fae36c7bfd95619857a84"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga42219a1c0426b6b8406403e902aa9f9c"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga42219a1c0426b6b8406403e902aa9f9c">g_flashMemoryInterface</a></td></tr>
<tr class="memdesc:ga42219a1c0426b6b8406403e902aa9f9c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Flash memory interface.  <a href="#ga42219a1c0426b6b8406403e902aa9f9c">More...</a><br /></td></tr>
<tr class="separator:ga42219a1c0426b6b8406403e902aa9f9c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1ac8541173ea5f76c889048abfaed8c5"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga1ac8541173ea5f76c889048abfaed8c5">g_normalMemoryInterface</a></td></tr>
<tr class="memdesc:ga1ac8541173ea5f76c889048abfaed8c5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory interface for memory with Normal type.  <a href="#ga1ac8541173ea5f76c889048abfaed8c5">More...</a><br /></td></tr>
<tr class="separator:ga1ac8541173ea5f76c889048abfaed8c5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae7cd8552c60aaf4639ead70b13edcac1"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gae7cd8552c60aaf4639ead70b13edcac1">g_normalDTCMInterface</a></td></tr>
<tr class="memdesc:gae7cd8552c60aaf4639ead70b13edcac1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory interface for memory with Normal type.  <a href="#gae7cd8552c60aaf4639ead70b13edcac1">More...</a><br /></td></tr>
<tr class="separator:gae7cd8552c60aaf4639ead70b13edcac1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga25ef1de51972c78edb2859aae717e75b"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga25ef1de51972c78edb2859aae717e75b">g_normalOCRAMInterface</a></td></tr>
<tr class="memdesc:ga25ef1de51972c78edb2859aae717e75b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory interface for memory with Normal type.  <a href="#ga25ef1de51972c78edb2859aae717e75b">More...</a><br /></td></tr>
<tr class="separator:ga25ef1de51972c78edb2859aae717e75b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6d612913b0600fd3f8fc0b5e6683df4a"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga6d612913b0600fd3f8fc0b5e6683df4a">g_deviceMemoryInterface</a></td></tr>
<tr class="memdesc:ga6d612913b0600fd3f8fc0b5e6683df4a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Memory interface for memory with Device or Strongly-ordered type.  <a href="#ga6d612913b0600fd3f8fc0b5e6683df4a">More...</a><br /></td></tr>
<tr class="separator:ga6d612913b0600fd3f8fc0b5e6683df4a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6ee7bc58f1a7bc485a14de63cbe03f41"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga6ee7bc58f1a7bc485a14de63cbe03f41"></a>
const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga6ee7bc58f1a7bc485a14de63cbe03f41">g_qspiMemoryInterface</a></td></tr>
<tr class="memdesc:ga6ee7bc58f1a7bc485a14de63cbe03f41"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to qspi memory operations. <br /></td></tr>
<tr class="separator:ga6ee7bc58f1a7bc485a14de63cbe03f41"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gafd77d1c0f5a7d2e92642386db370ecca"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gafd77d1c0f5a7d2e92642386db370ecca"></a>
const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gafd77d1c0f5a7d2e92642386db370ecca">g_qspiAliasAreaInterface</a></td></tr>
<tr class="memdesc:gafd77d1c0f5a7d2e92642386db370ecca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Interface to qspi alias area operations. <br /></td></tr>
<tr class="separator:gafd77d1c0f5a7d2e92642386db370ecca"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Generic memory interface implementation</h2></td></tr>
<tr class="memitem:ga0b91a8a20ec279fc2334836e42ba8fba"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga0b91a8a20ec279fc2334836e42ba8fba"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga0b91a8a20ec279fc2334836e42ba8fba">mem_init</a> (void)</td></tr>
<tr class="memdesc:ga0b91a8a20ec279fc2334836e42ba8fba"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialize memory interface. <br /></td></tr>
<tr class="separator:ga0b91a8a20ec279fc2334836e42ba8fba"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa8ad14f5408d549022d90f33b0181f80"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gaa8ad14f5408d549022d90f33b0181f80"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gaa8ad14f5408d549022d90f33b0181f80">mem_read</a> (uint32_t address, uint32_t length, uint8_t *buffer)</td></tr>
<tr class="memdesc:gaa8ad14f5408d549022d90f33b0181f80"><td class="mdescLeft">&#160;</td><td class="mdescRight">Read memory. <br /></td></tr>
<tr class="separator:gaa8ad14f5408d549022d90f33b0181f80"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga2209f6c45254fe9af56b27dbe2c3b51e"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga2209f6c45254fe9af56b27dbe2c3b51e"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga2209f6c45254fe9af56b27dbe2c3b51e">mem_write</a> (uint32_t address, uint32_t length, const uint8_t *buffer)</td></tr>
<tr class="memdesc:ga2209f6c45254fe9af56b27dbe2c3b51e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Write memory. <br /></td></tr>
<tr class="separator:ga2209f6c45254fe9af56b27dbe2c3b51e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga2a31dbf349b6c815dca6f1a5ae368f4d"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga2a31dbf349b6c815dca6f1a5ae368f4d"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga2a31dbf349b6c815dca6f1a5ae368f4d">mem_fill</a> (uint32_t address, uint32_t length, uint32_t pattern)</td></tr>
<tr class="memdesc:ga2a31dbf349b6c815dca6f1a5ae368f4d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Fill memory with a word pattern. <br /></td></tr>
<tr class="separator:ga2a31dbf349b6c815dca6f1a5ae368f4d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9c9db21262e44739939b2385def01d44"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga9c9db21262e44739939b2385def01d44"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga9c9db21262e44739939b2385def01d44">mem_erase</a> (uint32_t address, uint32_t length)</td></tr>
<tr class="memdesc:ga9c9db21262e44739939b2385def01d44"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase memory: <br /></td></tr>
<tr class="separator:ga9c9db21262e44739939b2385def01d44"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac5fd7b2e55ee75efd36fc2a74d12adbf"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gac5fd7b2e55ee75efd36fc2a74d12adbf">mem_flush</a> (void)</td></tr>
<tr class="memdesc:gac5fd7b2e55ee75efd36fc2a74d12adbf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Flush meory:  <a href="#gac5fd7b2e55ee75efd36fc2a74d12adbf">More...</a><br /></td></tr>
<tr class="separator:gac5fd7b2e55ee75efd36fc2a74d12adbf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga4d83e7bfdcbd68405f1284d40c0ecb55"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga4d83e7bfdcbd68405f1284d40c0ecb55">find_map_entry</a> (uint32_t address, uint32_t length, const <a class="el" href="group__memif.html#structmemory__map__entry__t">memory_map_entry_t</a> **map)</td></tr>
<tr class="memdesc:ga4d83e7bfdcbd68405f1284d40c0ecb55"><td class="mdescLeft">&#160;</td><td class="mdescRight">Find a map entry that matches address and length.  <a href="#ga4d83e7bfdcbd68405f1284d40c0ecb55">More...</a><br /></td></tr>
<tr class="separator:ga4d83e7bfdcbd68405f1284d40c0ecb55"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga67848881dc8f86c89530e67263361523"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga67848881dc8f86c89530e67263361523"></a>
bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga67848881dc8f86c89530e67263361523">mem_is_erased</a> (uint32_t address, uint32_t length)</td></tr>
<tr class="memdesc:ga67848881dc8f86c89530e67263361523"><td class="mdescLeft">&#160;</td><td class="mdescRight">Check is the specified memory region is erased. <br /></td></tr>
<tr class="separator:ga67848881dc8f86c89530e67263361523"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Memory utilities</h2></td></tr>
<tr class="memitem:ga2ddfb2158ed5330e06153e65d24beda9"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga2ddfb2158ed5330e06153e65d24beda9"></a>
bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga2ddfb2158ed5330e06153e65d24beda9">mem_is_block_reserved</a> (uint32_t address, uint32_t length)</td></tr>
<tr class="memdesc:ga2ddfb2158ed5330e06153e65d24beda9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determine if all or part of block is in a reserved region. <br /></td></tr>
<tr class="separator:ga2ddfb2158ed5330e06153e65d24beda9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Flash erase operations</h2></td></tr>
<tr class="memitem:ga4c6b555730dd1b726ec6cec5ae260639"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga4c6b555730dd1b726ec6cec5ae260639"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga4c6b555730dd1b726ec6cec5ae260639">flash_mem_erase</a> (uint32_t address, uint32_t length)</td></tr>
<tr class="memdesc:ga4c6b555730dd1b726ec6cec5ae260639"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase Flash memory. <br /></td></tr>
<tr class="separator:ga4c6b555730dd1b726ec6cec5ae260639"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga5e63718e006f188fb092c288ea433a2b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga5e63718e006f188fb092c288ea433a2b">flash_mem_erase_all</a> (<a class="el" href="group__memif.html#ga6265b0d880b733e90deb99d99c7868de">flash_erase_all_option_t</a> eraseOption)</td></tr>
<tr class="memdesc:ga5e63718e006f188fb092c288ea433a2b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all Flash memory or all Flash execute-only segments.  <a href="#ga5e63718e006f188fb092c288ea433a2b">More...</a><br /></td></tr>
<tr class="separator:ga5e63718e006f188fb092c288ea433a2b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0595ac3aa6fad85f453dc35494e07172"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#ga0595ac3aa6fad85f453dc35494e07172">flash_mem_erase_all</a> (void)</td></tr>
<tr class="memdesc:ga0595ac3aa6fad85f453dc35494e07172"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all Flash memory.  <a href="#ga0595ac3aa6fad85f453dc35494e07172">More...</a><br /></td></tr>
<tr class="separator:ga0595ac3aa6fad85f453dc35494e07172"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaeac0afc4294af489caf59cfadd804607"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gaeac0afc4294af489caf59cfadd804607"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gaeac0afc4294af489caf59cfadd804607">flash_mem_erase_all_unsecure</a> (void)</td></tr>
<tr class="memdesc:gaeac0afc4294af489caf59cfadd804607"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all Flash memory (unsecure). <br /></td></tr>
<tr class="separator:gaeac0afc4294af489caf59cfadd804607"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
QSPI erase operation</h2></td></tr>
<tr class="memitem:gaa20c114f199e3e936bb55351c0b7b855"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gaa20c114f199e3e936bb55351c0b7b855"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__memif.html#gaa20c114f199e3e936bb55351c0b7b855">qspi_mem_erase_all</a> (void)</td></tr>
<tr class="memdesc:gaa20c114f199e3e936bb55351c0b7b855"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all QSPI memory. <br /></td></tr>
<tr class="separator:gaa20c114f199e3e936bb55351c0b7b855"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Usage Information</h2>
<p>Abstract memory interface. </p>
<hr/><h2 class="groupheader">Data Structure Documentation</h2>
<a name="structmemory__interface__t" id="structmemory__interface__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct memory_interface_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"><p>Interface to memory operations. </p>
<p>This is the main abstract interface to all memory operations. </p>
</div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:aa46715850387c99c7e56add19eca83e5"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa46715850387c99c7e56add19eca83e5"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>init</b> )(void)</td></tr>
<tr class="separator:aa46715850387c99c7e56add19eca83e5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0456c80ba263677ada44200c8e90143c"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0456c80ba263677ada44200c8e90143c"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>read</b> )(uint32_t address, uint32_t length, uint8_t *buffer)</td></tr>
<tr class="separator:a0456c80ba263677ada44200c8e90143c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a06f31f52f18519a82cd17a4522144cf7"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a06f31f52f18519a82cd17a4522144cf7"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>write</b> )(uint32_t address, uint32_t length, const uint8_t *buffer)</td></tr>
<tr class="separator:a06f31f52f18519a82cd17a4522144cf7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a130ea7735a054c805d14a1f3f8774dc1"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a130ea7735a054c805d14a1f3f8774dc1"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>fill</b> )(uint32_t address, uint32_t length, uint32_t pattern)</td></tr>
<tr class="separator:a130ea7735a054c805d14a1f3f8774dc1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab03eb71194a79d300baf608864c498fe"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab03eb71194a79d300baf608864c498fe"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>flush</b> )(void)</td></tr>
<tr class="separator:ab03eb71194a79d300baf608864c498fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a79496bc8e80375946f97307ecec0fc72"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a79496bc8e80375946f97307ecec0fc72"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>erase</b> )(uint32_t address, uint32_t length)</td></tr>
<tr class="separator:a79496bc8e80375946f97307ecec0fc72"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>

</div>
</div>
<a name="structmemory__region__interface__t" id="structmemory__region__interface__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct memory_region_interface_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"><p>Interface to memory operations for one region of memory. </p>
</div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:aa46715850387c99c7e56add19eca83e5"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa46715850387c99c7e56add19eca83e5"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>init</b> )(void)</td></tr>
<tr class="separator:aa46715850387c99c7e56add19eca83e5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0456c80ba263677ada44200c8e90143c"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0456c80ba263677ada44200c8e90143c"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>read</b> )(uint32_t address, uint32_t length, uint8_t *buffer)</td></tr>
<tr class="separator:a0456c80ba263677ada44200c8e90143c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a06f31f52f18519a82cd17a4522144cf7"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a06f31f52f18519a82cd17a4522144cf7"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>write</b> )(uint32_t address, uint32_t length, const uint8_t *buffer)</td></tr>
<tr class="separator:a06f31f52f18519a82cd17a4522144cf7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a130ea7735a054c805d14a1f3f8774dc1"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a130ea7735a054c805d14a1f3f8774dc1"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>fill</b> )(uint32_t address, uint32_t length, uint32_t pattern)</td></tr>
<tr class="separator:a130ea7735a054c805d14a1f3f8774dc1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab03eb71194a79d300baf608864c498fe"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab03eb71194a79d300baf608864c498fe"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>flush</b> )(void)</td></tr>
<tr class="separator:ab03eb71194a79d300baf608864c498fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a79496bc8e80375946f97307ecec0fc72"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a79496bc8e80375946f97307ecec0fc72"></a>
<a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a>(*&#160;</td><td class="memItemRight" valign="bottom"><b>erase</b> )(uint32_t address, uint32_t length)</td></tr>
<tr class="separator:a79496bc8e80375946f97307ecec0fc72"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>

</div>
</div>
<a name="structmemory__map__entry__t" id="structmemory__map__entry__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct memory_map_entry_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"><p>Structure of a memory map entry. </p>
</div><div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-0-trigger" src="closed.png" alt="+"/> Collaboration diagram for memory_map_entry_t:</div>
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
<div class="center"><iframe scrolling="no" frameborder="0" src="structmemory__map__entry__t__coll__graph.svg" width="202" height="127"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
</div>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<table class="fieldtable">
<tr><th colspan="3">Data Fields</th></tr>
<tr><td class="fieldtype">
<a class="anchor" id="a4f8180c9e56e1eedbe45e7a2a9c25d85"></a>uint32_t</td>
<td class="fieldname">
endAddress</td>
<td class="fielddoc">
</td></tr>
<tr><td class="fieldtype">
<a class="anchor" id="a8b218105967928b1980e3b0eaae0d964"></a>bool</td>
<td class="fieldname">
isExecutable</td>
<td class="fielddoc">
</td></tr>
<tr><td class="fieldtype">
<a class="anchor" id="a4976239226aa3202cd67ad446d6c54a2"></a>const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> *</td>
<td class="fieldname">
memoryInterface</td>
<td class="fielddoc">
</td></tr>
<tr><td class="fieldtype">
<a class="anchor" id="a3a3fedf4660d77a61d25a4a70a2dfe3d"></a>uint32_t</td>
<td class="fieldname">
startAddress</td>
<td class="fielddoc">
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a class="anchor" id="gaac34dfe6c6b73b43a4656c9dce041034"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">anonymous enum</td>
        </tr>
      </table>
</div><div class="memdoc">
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a class="anchor" id="ggaac34dfe6c6b73b43a4656c9dce041034af06df00d223a4972f78ba2ed3282296c"></a>kMemoryNotExecutable&#160;</td><td class="fielddoc">
<p>The memory doesn't support executing in place. </p>
</td></tr>
<tr><td class="fieldname"><a class="anchor" id="ggaac34dfe6c6b73b43a4656c9dce041034acf4fb7fb9c61d4222ec903de4e194f1a"></a>kMemoryIsExecutable&#160;</td><td class="fielddoc">
<p>The memory supports executing in place. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="gada22a2d32e1fc49d3a94d7d78cc0eae1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__memif.html#gada22a2d32e1fc49d3a94d7d78cc0eae1">_memorymap_constants</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Memory Map index constants. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a class="anchor" id="ggada22a2d32e1fc49d3a94d7d78cc0eae1ae84ce932957cf2c1b62a763221d4ce2e"></a>kSRAMSeparatrix&#160;</td><td class="fielddoc">
<p>This value is the start address of SRAM_U. </p>
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="ga4d83e7bfdcbd68405f1284d40c0ecb55"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a> find_map_entry </td>
          <td>(</td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>address</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>length</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="group__memif.html#structmemory__map__entry__t">memory_map_entry_t</a> **&#160;</td>
          <td class="paramname"><em>map</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Find a map entry that matches address and length. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">address</td><td>Start address for the memory operation. </td></tr>
    <tr><td class="paramname">length</td><td>Number of bytes on which the operation will act. </td></tr>
    <tr><td class="paramname">map</td><td>The matching map entry is returned through this pointer if the return status is #kStatus_Success.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">#kStatus_Success</td><td>A valid map entry was found and returned through <em>map</em>. </td></tr>
    <tr><td class="paramname">#kStatusMemoryRangeInvalid</td><td>The requested address range does not match an entry, or the length extends past the matching entry's end address. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga5e63718e006f188fb092c288ea433a2b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a> flash_mem_erase_all </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__memif.html#ga6265b0d880b733e90deb99d99c7868de">flash_erase_all_option_t</a>&#160;</td>
          <td class="paramname"><em>eraseOption</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Erase all Flash memory or all Flash execute-only segments. </p>
<p>It is only valid for non-flash resident bootloader when option is erasing execute-only segments. </p>

</div>
</div>
<a class="anchor" id="ga0595ac3aa6fad85f453dc35494e07172"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a> flash_mem_erase_all </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Erase all Flash memory. </p>
<p>If building for flash resident bootloader, we have to decompose the the flash erase all operation into two region erases. This allows the user to still do an erase all, but not wipe out the bootloader itself. </p>

</div>
</div>
<a class="anchor" id="gac5fd7b2e55ee75efd36fc2a74d12adbf"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__ksdk__common.html#gaaabdaf7ee58ca7269bd4bf24efcde092">status_t</a> mem_flush </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Flush meory: </p>
<p>Flush buffered data into target memory.</p>
<dl class="section note"><dt>Note</dt><dd>1. This function should be called immediately after one write-memory command(either received in command packet or in sb file), only in this way, given data can be programmed at given address as expected.</dd></dl>
<ol type="1">
<li>So far, flush() is only implemented in qspi memory interface, for other memory interfaces, it is not available and <a class="el" href="group__memif.html#gac5fd7b2e55ee75efd36fc2a74d12adbf" title="Flush meory: ">mem_flush()</a> just returns kStatus_Success if it is called.</li>
<li>This function is designed to flush buffered data into target memory, please call it only if it is required to do so. For example, write 128 bytes to qspi flash, while the page size is 256 bytes, that means data might not be written to qspi memory immediately, since the internal buffer of qspi memory interface is not full, if no data are expected to write to left area of the same page, this function can be used to force to write immediately, otherwise, keep in mind that any calls should be avoided. If users voilate this rules, it would make the left area of the same page cannot be programmed.</li>
</ol>
<dl class="section return"><dt>Returns</dt><dd>An error code or kStatus_Success </dd></dl>

</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a class="anchor" id="ga6d612913b0600fd3f8fc0b5e6683df4a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> g_deviceMemoryInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Memory interface for memory with Device or Strongly-ordered type. </p>
<p>This memory type does not support multiword loads and stores.</p>
<p>Memory interface for memory with Device or Strongly-ordered type. </p>

</div>
</div>
<a class="anchor" id="ga42219a1c0426b6b8406403e902aa9f9c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> g_flashMemoryInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Flash memory interface. </p>
<p>Flash memory interface. </p>

</div>
</div>
<a class="anchor" id="gaa7d0fb25995fae36c7bfd95619857a84"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__interface__t">memory_interface_t</a> g_memoryInterface</td>
        </tr>
      </table>
</div><div class="memdoc">
<b>Initial value:</b><div class="fragment"><div class="line">= {</div><div class="line">    <a class="code" href="group__memif.html#ga0b91a8a20ec279fc2334836e42ba8fba">mem_init</a>,  <a class="code" href="group__memif.html#gaa8ad14f5408d549022d90f33b0181f80">mem_read</a>,  <a class="code" href="group__memif.html#ga2209f6c45254fe9af56b27dbe2c3b51e">mem_write</a>,</div><div class="line"><span class="preprocessor">#if !BL_FEATURE_MIN_PROFILE || BL_FEATURE_FILL_MEMORY</span></div><div class="line">    <a class="code" href="group__memif.html#ga2a31dbf349b6c815dca6f1a5ae368f4d">mem_fill</a>,</div><div class="line"><span class="preprocessor">#else</span></div><div class="line">    NULL,</div><div class="line"><span class="preprocessor">#endif </span></div><div class="line">    <a class="code" href="group__memif.html#gac5fd7b2e55ee75efd36fc2a74d12adbf">mem_flush</a>, <a class="code" href="group__memif.html#ga9c9db21262e44739939b2385def01d44">mem_erase</a>,</div><div class="line">}</div><div class="ttc" id="group__memif_html_gac5fd7b2e55ee75efd36fc2a74d12adbf"><div class="ttname"><a href="group__memif.html#gac5fd7b2e55ee75efd36fc2a74d12adbf">mem_flush</a></div><div class="ttdeci">status_t mem_flush(void)</div><div class="ttdoc">Flush meory: </div><div class="ttdef"><b>Definition:</b> memory.c:194</div></div>
<div class="ttc" id="group__memif_html_ga9c9db21262e44739939b2385def01d44"><div class="ttname"><a href="group__memif.html#ga9c9db21262e44739939b2385def01d44">mem_erase</a></div><div class="ttdeci">status_t mem_erase(uint32_t address, uint32_t length)</div><div class="ttdoc">Erase memory: </div><div class="ttdef"><b>Definition:</b> memory.c:121</div></div>
<div class="ttc" id="group__memif_html_ga0b91a8a20ec279fc2334836e42ba8fba"><div class="ttname"><a href="group__memif.html#ga0b91a8a20ec279fc2334836e42ba8fba">mem_init</a></div><div class="ttdeci">status_t mem_init(void)</div><div class="ttdoc">Initialize memory interface. </div><div class="ttdef"><b>Definition:</b> memory.c:278</div></div>
<div class="ttc" id="group__memif_html_gaa8ad14f5408d549022d90f33b0181f80"><div class="ttname"><a href="group__memif.html#gaa8ad14f5408d549022d90f33b0181f80">mem_read</a></div><div class="ttdeci">status_t mem_read(uint32_t address, uint32_t length, uint8_t *buffer)</div><div class="ttdoc">Read memory. </div><div class="ttdef"><b>Definition:</b> memory.c:74</div></div>
<div class="ttc" id="group__memif_html_ga2a31dbf349b6c815dca6f1a5ae368f4d"><div class="ttname"><a href="group__memif.html#ga2a31dbf349b6c815dca6f1a5ae368f4d">mem_fill</a></div><div class="ttdeci">status_t mem_fill(uint32_t address, uint32_t length, uint32_t pattern)</div><div class="ttdoc">Fill memory with a word pattern. </div><div class="ttdef"><b>Definition:</b> memory.c:155</div></div>
<div class="ttc" id="group__memif_html_ga2209f6c45254fe9af56b27dbe2c3b51e"><div class="ttname"><a href="group__memif.html#ga2209f6c45254fe9af56b27dbe2c3b51e">mem_write</a></div><div class="ttdeci">status_t mem_write(uint32_t address, uint32_t length, const uint8_t *buffer)</div><div class="ttdoc">Write memory. </div><div class="ttdef"><b>Definition:</b> memory.c:91</div></div>
</div><!-- fragment -->
<p>Interface to generic memory operations. </p>
<p>Abstract memory interface. </p>

</div>
</div>
<a class="anchor" id="gaa7d0fb25995fae36c7bfd95619857a84"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__interface__t">memory_interface_t</a> g_memoryInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Abstract memory interface. </p>
<p>This interface utilizes the memory map to perform different memory operations depending on the region of memory being accessed.</p>
<p>Abstract memory interface. </p>

</div>
</div>
<a class="anchor" id="gae7cd8552c60aaf4639ead70b13edcac1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> g_normalDTCMInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Memory interface for memory with Normal type. </p>
<p>Use of multiword loads and stores is allowed with this memory type.</p>
<p>Memory interface for memory with Normal type. </p>

</div>
</div>
<a class="anchor" id="ga1ac8541173ea5f76c889048abfaed8c5"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> g_normalMemoryInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Memory interface for memory with Normal type. </p>
<p>Use of multiword loads and stores is allowed with this memory type.</p>
<p>Memory interface for memory with Normal type. </p>

</div>
</div>
<a class="anchor" id="ga25ef1de51972c78edb2859aae717e75b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="group__memif.html#structmemory__region__interface__t">memory_region_interface_t</a> g_normalOCRAMInterface</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Memory interface for memory with Normal type. </p>
<p>Use of multiword loads and stores is allowed with this memory type.</p>
<p>Memory interface for memory with Normal type. </p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated on Mon Mar 7 2016 16:48:23 for Kinetis Bootloader by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
  </ul>
</div>
</body>
</html>
